<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<style>

    .box {
        width: 500px;
        margin: auto;
        padding: 20px;
        box-sizing: border-box;
        background-color: lightgray;
    }

    .wrapper {
        display: grid;
        grid-template-columns: 1fr;
        grid-template-rows: auto 0fr;
        transition: grid-template-rows .7s;
    }

    .content {
        overflow: hidden;
    }

    .wrapper:hover {
        grid-template-rows: auto 1fr;
    }


</style>
<body>
    
    <div class="box">

        <div class="wrapper">
            <div>HTML</div>
            <div class="content">
                Lorerm asdd rew sadaw dsacx asdas dsada dsadawqwr assa a  sa  sa sa sa sa s sa  dwwe
            </div>
        </div>

    </div>

</body>
</html>